package com.example.avue.util;

public class ResResult<T> {
    int code;
    String msg;
    boolean success;
    T data;

    public ResResult<T> setCode(ResCode retCode) {
        this.code = retCode.code;
        return this;
    }

    public int getCode() {
        return code;
    }

    public ResResult<T> setCode(int code) {
        this.code = code;
        return this;
    }

    public String getMsg() {
        return msg;
    }

    public ResResult<T> setMsg(String msg) {
        this.msg = msg;
        return this;
    }

    public boolean getSuccess() {
        return success;
    }

    public ResResult<T> setSuccess(boolean success) {
        this.success = success;
        return this;
    }

    public T getData() {
        return data;
    }

    public ResResult<T> setData(T data) {
        this.data = data;
        return this;
    }
}
